//
//  TextureManager.h
//  Void Dead
//
//  Created by Sidney Just on 03.07.09.
//  Copyright 2009 by Sidney Just
//  This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; 
//  either version 3 of the License, or (at your option) any later version.
//  
//  This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty 
//  of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
//  


#import <Foundation/Foundation.h>
#import "VDead.h"

@class VD_Vector;

/** 
 * This class manages every texture that will be created
 * You normally don't need to create this by hand because a instance will be provided by the VD_Engine class
 **/
@interface VD_TextureManager : NSObject {
	GLuint		*texLib;
	VD_Vector	**size;
	BOOL		*hasAlpha;
	NSString	**loadedTextures;
	
	@private
	int textures;
}

/** 
 * The texture library used by the engine
 **/
@property (nonatomic, readonly) GLuint *texLib;

@property (nonatomic, readonly) BOOL *hasAlpha;

/** 
 * The size of every Texture in pixels
 **/
@property (nonatomic, readonly) VD_Vector **size;

@property (nonatomic, readonly) NSString **loadedTextures;

/**
 * loads the given texture into the memory. If the texture is already loaded, it returns only the reference
 @param str Path to the texture file
 @return Reference to the texture
 **/
- (int)loadATexture:(NSString *)str;

/**
 * Deletes the given texture.
 @param str Path to the texture file
 **/
- (void)deleteTexture:(NSString *)str;

@end
